/**
 * author wen
 * &copy; CUNYU GROUP
 * email wjd_13@hotmail.com
 */
package com.cunyu.service;

import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * 统计信息
 * @author win
 * 2019/05/14-16:15
 */
@Service
public class CountService extends BaseService{

    //城市订单数量
    public List<Map<String, Object>> cityBaseCoustorNumbers(int pcode){
        String sql = "select p.citycode ,count(p.*) num,(select c.name from codecity c where c.code = p.citycode) cityname" +
                " from orderpool p where p.citycode in (select code from codecity where pcode = ?) " +
                " group by p.citycode " ;

        return getList(sql,pcode) ;
    }

}
